<template>
	<view class="page">
		<navBar title="我的水晶" :change="scrollChange"></navBar>
		<view class="act-rule" @click="navTo('balance')">明细</view>
		<view class="container">
			<view class="section-header">
				<view class="balance">
					<view class="balance-text">水晶余额</view>
					<view class="balance-number">{{money}}</view>
				</view>
				<view class="frozen-wrap">
					<view class="frozen">
						<view class="flex align-center">
							<image src="/static/icon/icon_freeze.png" />
							<view>冻结水晶：{{freezeAmount}}</view>
						</view>
					</view>
				</view>
				<view class="profit flex">
					<view class="now-profit flex-sub text-center">
						<view class="title">今日收益</view>
						<view class="number">{{todayAmount}}</view>
					</view>
					<view class="all-profit flex-sub text-center">
						<view class="title">累计收益</view>
						<view class="number">{{totalAmount}}</view>
					</view>
				</view>
				<view class="btns flex justify-between">
					<view class="withdrawal" @click="gopage">提现</view>
					<view class="recharge" @click="aliShow">充值</view>
				</view>
			</view>
			<view class="section-content">
				<view class="details">
					<view class="details-titel">收益明细</view>
					<scroll-view scroll-x class="bg-white nav" scroll-with-animation :scroll-left="scrollLeft">
						<view class="cu-item" :class="index==TabCur?'text-green cur':''" v-for="(item,index) in navList" :key="index"
						 @tap="tabSelect" :data-id="index">
							<view @click="qiehuan(item.id)">
								{{ item.name }}
							</view>
						</view>
					</scroll-view>
				</view>
				<view class="details-list">
					<view class="list" v-for="(item,index) in shouyilist" :key="index">
						<view class="list-title flex justify-between">
							<view>{{item.note}}</view>
							<text> <span v-if="item.status == 1" style="margin-right: 20upx;font-size: 36upx;font-weight: 400;">+</span>
								<span v-if="item.status == 2 || item.status == 4" style="margin-right: 20upx;font-size: 36upx;font-weight: 400;">-</span>
								{{item.price}}
								<span v-if="item.status == 3" style="margin-left: 10upx;font-size: 26upx;font-weight: 400;">冻结</span>
								<span v-if="item.status == 4" style="margin-left: 10upx;font-size: 26upx;font-weight: 400;">退货代扣</span>
							</text>
						</view>
						<view class="list-time">
							{{item.createTime}}
						</view>
					</view>
				</view>
			</view>
		</view>
		<loadMore :status="loadingType"></loadMore>
	</view>
</template>

<script>
	import mallplusCopyright from '@/components/mall-copyright/mallplusCopyright.vue';
	import Api from '@/common/api';
	import eonfox from '@/components/eonfox/eonfox.js';
	import fns from '@/components/eonfox/fns.js';
	import navBar from "@/components/header-nav";
	import loadMore from '@/components/load-more';

	var ef = new eonfox()
	export default {
		components: {
			loadMore,
			navBar
		},
		data() {
			return {
				headerHeight: 0,
				scrollChange: false,
				money: 0,
				inputAmount: '', //金额
				amountList: [100, 200, 500], //预设3个可选快捷金额
				paytype: 'wxpay', //支付类型
				navList: [{
					name: '分享收益', //推荐收益就是分享收益
					id: 1
				}, {
					name: '砍价红包',
					id: 2
				}, {
					name: '购物津贴',
					id: 3
				}, {
					name: '销售收益',
					id: 4
				}, {
					name: '团队收益',
					id: 5
				}, {
					name: '广告收益',
					id: 6
				}],
				TabCur: 0,
				scrollLeft: 0,
				loadingType: 'loading', //加载更多状态
				currentPage: 1,
				pageTotal: 10,
				// 冻结金额
				freezeAmount: 0,
				// 今日收益
				todayAmount: 0,
				// 累计收益
				totalAmount: 0,
				shouyilist: [],
				id: 1,
				pageSize: 10,
				allpages: 0
			};
		},
		//分页
		async onReachBottom() {
			if (this.currentPage < this.allpages) {
				this.currentPage++;
				let params = {
					pageNum: this.currentPage,
					pageSize: this.pageSize,
					type: this.id
				};
				let data = await Api.apiCall('get', Api.money.shuijingList, params);
				this.currentPage = data.current; //当前页
				this.pageTotal = data.total; //总公多少条
				this.allpages = data.pages; //总页数
				// data.records = data.records.reverse()
				for (let i = 0; i < data.records.length; i++) {
					data.records[i].createTime = this.newtime(data.records[i].createTime);
				}
				this.shouyilist = this.shouyilist.concat(data.records);
				// this.shouyilist = data.records.concat(this.shouyilist);
				
				if (data.pages == this.currentPage) {
					this.loadingType = 'noMore'
				}
			} else {
				this.loadingType = 'noMore'
			}
		},
		async onShow() {
			this.load()
			this.qiehuan(1)
		},
		onReady() {
			this.headerHeight = uni.getStorageSync('headerHeight');
		},
		onPageScroll(e) {
			if (e.scrollTop > this.headerHeight) {
				this.scrollChange = true
			} else {
				this.scrollChange = false
			}
		},
		methods: {
			aliShow() {
				uni.navigateTo({
					url: './chongzhi'
				})
			},
			navTo(e) {
				uni.navigateTo({
					url: e
				});
			},
			async qiehuan(id) {
				this.id = id;
				let params
				if (id == 7) {
					this.id = 2;
					params = {
						pageNum: 1,
						pageSize: this.pageSize,
						type: this.id,
						// isDone: 1
					};
				} else {
					params = {
						pageNum: 1,
						pageSize: this.pageSize,
						type: this.id
					};
				}
				let data1 = await Api.apiCall('get', Api.money.shuijingList, params);
				this.currentPage = data1.current; //当前页
				this.pageTotal = data1.total; //总公多少条
				this.allpages = data1.pages; //总页数
				// this.shouyilist = data1.records.reverse();
				this.shouyilist = data1.records;
				var that = this;
				for (let i = 0; i < that.shouyilist.length; i++) {
					that.shouyilist[i].createTime = that.newtime(that.shouyilist[i].createTime);
				}
				if (data1.pages == this.currentPage) {
					this.loadingType = 'noMore'
				}
			},
			async load() {
				let params = {};
				let data1 = await Api.apiCall('get', 'single/user/myAmount', params);
				// //console.log(data1)
				this.money = data1.amount;
				this.freezeAmount = data1.freezeAmount;
				this.todayAmount = data1.todayAmount;
				this.totalAmount = data1.totalAmount;
			},
			newtime(timestamp) {
				// let type = typeof timestamp;
				if (timestamp == '' || timestamp == null || timestamp == undefined) {
					return ''
				} else {
					var date = new Date(timestamp); //时间戳为10位需*1000，时间戳为13位的话不需乘1000
					var Y = date.getFullYear() + '-';
					var M = (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1) + '-';
					var D = (date.getDate() < 10 ? '0' + date.getDate() : date.getDate()) + ' ';
					var h = (date.getHours() < 10 ? '0' + date.getHours() : date.getHours()) + ':';
					var m = (date.getMinutes() < 10 ? '0' + date.getMinutes() : date.getMinutes()) + ':';
					var s = (date.getSeconds() < 10 ? '0' + date.getSeconds() : date.getSeconds());
					var strDate = Y + M + D + h + m + s;
					return strDate;
				}
			},

			add0(m) {
				return m < 10 ? '0' + m : m
			},
			async onload() {
				let params = {};
				let data1 = await Api.apiCall('get', Api.index.currentMember, params);
				this.money = data1.blance;
			},
			select(amount) {
				this.inputAmount = amount;
			},
			tabSelect(e) {
				// //console.log(e)
				this.TabCur = e.currentTarget.dataset.id;
				this.scrollLeft = (e.currentTarget.dataset.id - 1) * 60
			},
			doDeposit() {
				if (this.paytype == 'alipay') {
					//console.log('支付宝')

					return
				} else {
					//console.log('微信')
					return
				}
				if (parseFloat(this.inputAmount).toString() == "NaN") {
					uni.showToast({
						title: '请输入正确金额',
						icon: 'none'
					});
					return;
				}
				if (this.inputAmount <= 0) {
					uni.showToast({
						title: '请输入大于100的金额',
						icon: 'none'
					});
					return;
				}
				if (parseFloat(this.inputAmount).toFixed(2) != parseFloat(this.inputAmount)) {
					uni.showToast({
						title: '最多只能输入两位小数哦~',
						icon: 'none'
					});
					return;
				}
				//模板模拟支付，实际应用请调起微信/支付宝
				uni.showLoading({
					title: '支付中...'
				});
				setTimeout(() => {
					uni.hideLoading();
					uni.showToast({
						title: '支付成功'
					});
					setTimeout(() => {
						uni.switchTab({
							url: '../../pages/index/user'
						});
					}, 300);
				}, 700)
			},
			pay() {
				var _this = this
				if (!/^\d+(\.\d+)?$/.test(_this.inputAmount) || _this.inputAmount <= 0) {
					uni.showToast({
						title: '请输入正确金额',
						icon: 'none'
					})
				} else {
					if (_this.paytype != 'alipay') {
						_this.WeChatPay()
						// // #ifdef MP-WEIXIN
						// _this.pay_mp_weixin()
						// // #endif
						// // #ifdef APP-PLUS || H5
						// _this.pay_APP_weixin()
						// // #endif
					}
					if (_this.paytype == 'alipay') {
						// #ifdef H5 || MP-WEIXIN
						uni.showToast({
							title: '开发中。。。',
							icon: 'none'
						});
						// #endif
						// #ifdef APP-PLUS
						_this.payAli();
						// #endif
					}

				}

			},
			payAli() {
				var _this = this;
				ef.submit({
					request: {
						s: ['APPLICATIONORDERSELFBUYUSERMONEY', [{
							money_fen: _this.inputAmount * 100, //必须|要购买余额(人民币，分)
							pay_method: 'alipay', //支付方式 weixinpay 微信支付、alipay 支付宝支付
							alipay_trade_type: 'APP'
						}]]
					},
					callback(data) {
						//console.log('调起支付宝支付', data)

						fns.checkError(data, 's', function(errno, error) {
							uni.showToast({
								title: error,
								icon: 'none'
							})

						})
						var ali = data.data.s.data.alipay
						if (ali) {
							uni.requestPayment({
								provider: 'alipay',
								orderInfo: ali,
								success: function(res) {
									//console.log('success:' + JSON.stringify(res));
									_this.onload()
									uni.showToast({
										title: '充值成功',
										icon: 'none'
									})
								},
								fail: function(err) {
									//console.log('fail:' + JSON.stringify(err));
								}
							});
						}
					},
					error(err) {
						fns.err('提交订单失败', err, 1)
					}


				})
			},
			// 微信充值
			WeChatPay() {
				var _this = this
				// if (!/^\d+(\.\d+)?$/.test(_this.pay_money) || _this.pay_money <= 0) {
				// 	uni.showToast({
				// 		title: '请输入正确金额',
				// 		icon: 'none'
				// 	});
				// }else{
				var money_fen = _this.inputAmount * 100
				// if(_this.tabIndex!=0){
				// 	money_fen=_this.tabIndex*100
				// }else{
				// 	money_fen=_this.pay_money*100
				// }
				// APP充值
				// #ifdef APP-PLUS
				ef.submit({
					request: {
						s: [
							'APPLICATIONORDERSELFBUYUSERMONEY',
							[{
								money_fen: money_fen, //必须|要购买余额(人民币，分)
								pay_method: 'weixinpay', //支付方式 weixinpay 微信支付、alipay 支付宝支付
								weixin_trade_type: 'APP'
							}]
						]
					},
					callback: function(data) {
						//console.log('商家', data);
						if (
							fns.checkError(data, 's', function(erron, error) {
								uni.showToast({
									title: error,
									icon: 'none'
								});
								_this.pay_switch = false;
							})
						) {
							//7,已支付
							//发起支付
							//console.log('发起支付', data.data.s.data);
							_this.requestPayment(data.data.s.data);
							//获取成功，无错误信息时
						}
					},
					error(err) {
						fns.err('提交订单失败', err, 1);
					}
				});
				// #endif

				//#ifdef  MP-WEIXIN
				wx.login({
					//微信小程序登录获取code
					success(res) {
						// #ifdef MP-WEIXIN
						_this.code = res.code;
						// #endif
						// #ifdef APP-PLUS
						_this.code = res.authResult.openid;
						// #endif
						if (_this.code) {
							//获取到code生成订单
							// 发起网络请求
							//console.log('发起网络请求');
							ef.submit({
								request: {
									s: [
										'APPLICATIONORDERSELFBUYUSERMONEY',
										[{
											money_fen: money_fen, //必须|要购买余额(人民币，分)
											// #ifdef MP-WEIXIN
											weixin_login_code: _this.code,
											pay_method: 'weixinpay', //支付方式 weixinpay 微信支付、alipay 支付宝支付
											weixin_trade_type: 'JSAPI',
											// #endif
											// #ifdef APP-PLUS
											weixin_login_openid: _this.code,
											pay_method: 'weixinpay', //支付方式 weixinpay 微信支付、alipay 支付宝支付
											weixin_trade_type: 'APP'
											// #endif
										}]
									]
								},
								callback: function(data) {
									//console.log('商家', data);
									if (
										fns.checkError(data, 's', function(erron, error) {
											uni.showToast({
												title: error,
												icon: 'none'
											});
											_this.pay_switch = false;
										})
									) {
										//7,已支付
										//发起支付
										//console.log('发起支付', data.data.s.data);
										_this.requestPayment(data.data.s.data);
										//获取成功，无错误信息时
									}
								},
								error: function(err) {
									//console.log('出错啦', err);
									uni.showToast({
										title: JSON.stringify(err),
										icon: 'none'
									});
									_this.pay_switch = false;
								}
							});
						} else {
							_this.pay_switch = false;
							//console.log('登录失败！' + res.errMsg);
							uni.showToast({
								title: '登录失败！' + res.errMsg,
								icon: 'none'
							});
						}
					},
					fail() {
						_this.pay_switch = false;
					}
				});
				// #endif

				//#ifdef H5
				ef.submit({
					request: {
						s: ['SESSIONWEIXINACCESSTOKEN']
					},
					callback(data) {
						var dataList = fns.checkError(data, 's', function(errno, error) {
							uni.showToast({
								title: '请先确认微信授权',
								icon: 'none'
							})
						})
						//console.log(dataList);
						if (dataList.s) {
							ef.submit({
								request: {
									s: ['APPLICATIONORDERSELFBUYUSERMONEY',
										[{
											money_fen: money_fen, //必须|要购买余额(人民币，分)
											pay_method: 'weixinpay', //支付方式 weixinpay 微信支付、alipay 支付宝支付
											weixin_trade_type: 'MPJSAPI',
											weixin_login_openid: dataList.s.openid
										}]
									]
								},

								callback(data) {
									//console.log('调起微信支付', data);
									var dataList = fns.checkError(data, 's', function(errno, error) {
										uni.showToast({
											title: error,
											icon: 'none'
										});
									});
									var ress = dataList.s;
									if (ress) {
										//console.log('ress', ress);

										var getBrandWCPayRequest = {
											appId: ress.appid,
											timeStamp: String(ress.time_stamp), // 支付签名时间戳，注意微信jssdk中的所有使用timestamp字段均为小写。但最新版的支付后台生成签名使用的timeStamp字段名需大写其中的S字符
											nonceStr: ress.nonce_str, // 支付签名随机串，不长于 32 位
											package: 'prepay_id=' + ress.prepay_id, // 统一支付接口返回的prepay_id参数值，提交格式如：prepay_id=\*\*\*）
											signType: ress.sign_type, // 签名方式，默认为'SHA1'，使用新版支付需传入'MD5'
											paySign: ress.pay_sign, // 支付签名
										};

										//console.log('getBrandWCPayRequest', getBrandWCPayRequest);

										function onBridgeReady() {
											WeixinJSBridge.invoke(
												'getBrandWCPayRequest', getBrandWCPayRequest,
												function(res) {
													if (res.err_msg == "get_brand_wcpay_request:ok") {
														uni.showToast({
															title: '支付成功',
															success() {
																// setTimeout(function() {
																// 	uni.navigateTo({
																// 		url: '../../pagesB/my-order/my-order'
																// 	});
																// }, 2000)
															}
														})
													}
													if (res.err_msg == "get_brand_wcpay_request:fail") {
														uni.showToast({
															title: '支付失败',
															icon: 'none'
														})
													}
													if (res.err_msg == "get_brand_wcpay_request:cancel") {
														uni.showToast({
															title: '已取消支付',
															icon: 'none',
															success() {
																setTimeout(function() {
																	uni.navigateBack({
																		delta: 1
																	});
																}, 1500)
															}
														})
													}
												});
										}

										if (typeof WeixinJSBridge == "undefined") {
											if (document.addEventListener) {
												document.addEventListener('WeixinJSBridgeReady', onBridgeReady, false);
											} else if (document.attachEvent) {
												document.attachEvent('WeixinJSBridgeReady', onBridgeReady);
												document.attachEvent('onWeixinJSBridgeReady', onBridgeReady);
											}
										} else {
											onBridgeReady();
										}

									} else {
										//console.log('提交订单失败', ress);
										_this.payWeChatPMJSAPI();

									}
									//console.log('提交订单', ress);

								},
								error(err) {
									//console.log('提交订单失败', err, 1);
								}
							});


						} else {

							//console.log('location', location.href);

							//当 ACCESSTOKEN 不存在
							ef.left_token(function(left_token) {
								var notify_url = encodeURIComponent(location.href);
								var url = ef.api_server_url + "?" + encodeURI('data=[["SESSIONWEIXINAUTHORIZE",[{"notify_url":"' +
									notify_url + '"}]]]') + "&token=" + left_token;
								//console.log(url);
								location.href = url;
							});

						}
					},
					error(err) {
						fns.err('err', err, 1)
					}
				})
				// #endif

				// }
			},
			//app微信支付
			pay_APP_weixin() {
				var _this = this;
				ef.submit({
					request: {
						s: [
							'APPLICATIONORDERSELFBUYUSERMONEY',
							[{
								money_fen: _this.pay_money * 100, //必须|要购买余额(人民币，分)
								pay_method: 'weixinpay', //支付方式 weixinpay 微信支付、alipay 支付宝支付
								weixin_trade_type: 'APP'
							}]
						]
					},
					callback: function(data) {
						//console.log('商家', data);
						if (
							fns.checkError(data, 's', function(erron, error) {
								uni.showToast({
									title: error,
									icon: 'none'
								});
								_this.pay_switch = false;
							})
						) {
							//7,已支付
							//发起支付
							//console.log('发起支付', data.data.s.data);
							_this.requestPayment(data.data.s.data);
							//获取成功，无错误信息时
						}
					},
					error(err) {
						fns.err('提交订单失败', err, 1);
					}
				});
			},
			//微信小程序支付
			pay_mp_weixin() {
				var _this = this;
				wx.login({
					//微信小程序登录获取code
					success(res) {
						// #ifdef MP-WEIXIN
						_this.code = res.code;
						// #endif
						// #ifdef APP-PLUS
						_this.code = res.authResult.openid;
						// #endif
						if (_this.code) {
							//获取到code生成订单
							// 发起网络请求
							//console.log('发起网络请求');
							ef.submit({
								request: {
									s: [
										'APPLICATIONORDERSELFBUYUSERMONEY',
										[{
											money_fen: _this.pay_money * 100, //必须|要购买余额(人民币，分)
											// #ifdef MP-WEIXIN
											weixin_login_code: _this.code,
											pay_method: 'weixinpay', //支付方式 weixinpay 微信支付、alipay 支付宝支付
											weixin_trade_type: 'JSAPI',
											// #endif
											// #ifdef APP-PLUS
											weixin_login_openid: _this.code,
											pay_method: 'weixinpay', //支付方式 weixinpay 微信支付、alipay 支付宝支付
											weixin_trade_type: 'APP'
											// #endif
										}]
									]
								},
								callback: function(data) {
									//console.log('商家', data);
									if (
										fns.checkError(data, 's', function(erron, error) {
											uni.showToast({
												title: error,
												icon: 'none'
											});
											_this.pay_switch = false;
										})
									) {
										//7,已支付
										//发起支付
										//console.log('发起支付', data.data.s.data);
										_this.requestPayment(data.data.s.data);
										//获取成功，无错误信息时
									}
								},
								error: function(err) {
									//console.log('出错啦', err);
									uni.showToast({
										title: JSON.stringify(err),
										icon: 'none'
									});
									_this.pay_switch = false;
								}
							});
						} else {
							_this.pay_switch = false;
							//console.log('登录失败！' + res.errMsg);
							uni.showToast({
								title: '登录失败！' + res.errMsg,
								icon: 'none'
							});
						}
					},
					fail() {
						_this.pay_switch = false;
					}
				});
			},
			requestPayment(wxArr) {
				var _this = this;
				_this.test = '开始了';
				var _this = this;
				//console.log('支付参数' + JSON.stringify(wxArr));
				//console.log('调起支付');
				_this.test = '调起支付';

				// #ifdef APP-PLUS
				var orderInfo = {
					appid: wxArr.appid,
					partnerid: wxArr.mch_id, //商户号
					prepayid: wxArr.prepay_id, //预支付交易会话ID
					package: 'Sign=WXPay', //扩展字段,暂填写固定值Sign=WXPay
					noncestr: wxArr.nonce_str, //随机字符串
					timestamp: wxArr.time_stamp, //时间戳
					sign: wxArr.pay_sign //签名
				};
				// #endif

				uni.requestPayment({
					// #ifdef MP-WEIXIN
					provider: 'wxpay',
					timeStamp: String(wxArr.time_stamp),
					nonceStr: wxArr.nonce_str,
					package: 'prepay_id=' + wxArr.prepay_id,
					signType: wxArr.sign_type,
					paySign: wxArr.pay_sign,
					orderInfo: wxArr,
					// #endif
					// #ifdef APP-PLUS
					provider: 'wxpay',
					orderInfo: JSON.stringify(orderInfo),
					// #endif
					success: function(res) {
						//console.log('成功success:' + JSON.stringify(res));
						if (res.errMsg == 'requestPayment:ok') {
							_this.pay_switch = false;
							//支付成功是进行订单查询
							var out_time = 0;
							var timeTn = setInterval(function() {
								out_time++;
								if (out_time <= 30) {
									_this.pay_result_query(wxArr.order_id, function() {
										clearInterval(timeTn);
										_this.onload();
										uni.showToast({
											title: '充值成功',
											icon: 'none'
										});
									});
								} else {
									uni.showToast({
										title: '业务超时，如已支付，请稍后再个人页面查看是否到账',
										icon: 'none'
									});
								}
							}, 1000);
						} else {
							uni.showToast({
								title: '业务超时，如已支付，请稍后再个人页面查看是否到账',
								icon: 'none'
							});
							_this.pay_switch = false;
						}
					},
					fail: function(err) {
						_this.pay_switch = false;
						return false;
					}
				});
			},
			//支付结果查询（订单号）
			pay_result_query(order_id, fun) {
				//console.log('正在查询');
				ef.submit({
					request: {
						s: [
							'APPLICATIONORDERSELFPAYSTATE',
							[{
								order_id: order_id
							}]
						]
					},
					callback: function(data) {
						// //console.log('支付查询回调成功',data.data.s.data) ;return data.data.s.data;
						if (
							fns.checkError(data, 's', function(errno, error) {
								return false;
							})
						) {
							fun();
						}
					},
					error: function(err) {
						return 0;
					}
				});
			},

			gominxi() {
				uni.navigateTo({
					url: '../../pagesU/user/balance'
				})
			},
			gopage() {
				uni.navigateTo({
					url: '../../pagesU/user/myPurse'
				})
			},
		},
		onLoad() {

		},
	}
</script>

<style lang="scss">
	.page {
		width: 100%;
		min-height: 100vh;
		background: linear-gradient(to bottom, #FFAC07, #fff);

		.container {
			.section-header {
				margin-top: 40upx;
				margin-left: 30upx;
				margin-right: 30upx;
				padding: 80upx 40upx 60upx;
				background: #fff;
				border-radius: 30upx;

				.balance {
					text-align: center;

					.balance-text {
						padding-bottom: 25upx;
						font-size: 36upx;
						color: #666;
					}

					.balance-number {
						color: #333;
						font-size: 86upx;
					}
				}

				.frozen-wrap {
					width: 100%;
					text-align: center;
					padding: 40upx 0;

					.frozen {
						display: inline-block;
						padding: 12upx 24upx;
						border-radius: 29upx;
						background: #FEF0CC;

						image {
							width: 32upx;
							height: 32upx;
						}

						view {
							margin-left: 20upx;
							font-size: 24upx;
							color: #666;
						}
					}
				}

				.profit {
					.title {
						font-size: 28upx;
						color: #999;
					}

					.number {
						padding-top: 18upx;
						font-size: 42upx;
						color: #333;
					}
				}

				.btns {
					margin-top: 80upx;

					view {
						width: calc(50% - 25upx);
						height: 88upx;
						line-height: 88upx;
						font-size: 36upx;
						text-align: center;
						font-weight: bold;
						border-radius: 44upx;
					}

					.withdrawal {
						color: #F94242;
						border: 1upx solid #F94242;
					}

					.recharge {
						color: #fff;
						background: linear-gradient(to right, #FF7777, #FF1D1D);
					}
				}
			}

			.section-content {
				min-height: 50vh;
				margin-top: 46upx;
				background: #fff;
				box-shadow: 0px -1upx 0px 0px rgba(153, 153, 153, 0.4);
				border-radius: 30upx 30upx 0px 0px;

				.details {
					padding: 30upx;

					.details-titel {
						font-size: 32upx;
						font-weight: bold;
						padding-bottom: 30upx;
					}

					.nav .cu-item {
						width: 180upx;
						height: 58upx;
						line-height: 58upx;
						border-radius: 33upx;
						text-align: center;
						margin-left: 30upx;
						font-size: 32upx;
						font-weight: bold;
					}

					.nav .cu-item:first-child {
						margin-left: 0;
					}

					.nav .cu-item.cur {
						border: 0;
						color: #fff;
						background: linear-gradient(135deg, rgba(255, 119, 119, 1) 0%, rgba(255, 29, 29, 1) 100%);
					}
				}

				.details-list {
					border-top: 1upx solid #999;

					.list {
						padding: 36upx 30upx;

						.list-title {
							font-weight: bold;

							view {
								font-size: 36upx;
								color: #333;
							}

							text {
								font-size: 42upx;
								color: #F94242;
							}
						}

						.list-time {
							font-size: 28upx;
							color: #999;
							padding-top: 25upx;
						}
					}
				}
			}
		}
	}
</style>
